package com.example.service;

import com.example.dao.mysql01.OrderDao;
import com.example.dao.mysql02.UserDao;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
@Slf4j
public class TestServiceImpl implements TestService {


    @Autowired
    private OrderDao orderDao;

    @Autowired
    private UserDao userDao;


    @Override
    public void test() {

        List<Map<String, Object>> list1 = orderDao.getllOrder();
        log.info("所有订单:{}", list1.toString());

        List<Map<String, Object>> list2 = userDao.getllUser();
        log.info("所有用户:{}", list2.toString());

    }
}
